import { translateTitle } from '@/utils/i18n'
const MessageConfig = {
  MessageConfig: {
    search: {
      form: {
        method: 'ApimMessageConfigQuery',
        name: 'search',
        field: [
          {
            type: 'input',
            name: 'MESSAGE_GROUP_ID',
            label: translateTitle('Dams.APIMinterfaceManagement.消息集ID'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'MESSAGE_ID',
            label: translateTitle('Dams.APIMinterfaceManagement.接口编号'),
            labelHidden: false,
          },
          {
            type: 'button',
            label: translateTitle('Dams.APIMinterfaceManagement.查询'),
            labelHidden: true,
          },
        ],
      },
    },
    dialog: {
      form: {
        method: '',
        name: 'dialog',
        field: [
          {
            type: 'checkbox',
            name: 'ID',
            label: '',
            hidden: true,
          },
          {
            type: 'input',
            name: 'MESSAGE_GROUP_ID',
            label: translateTitle('Dams.APIMinterfaceManagement.消息集编号'),
            labelHidden: false,
            isRules: true,
            disabled_edit: true,
          },
          {
            type: 'input',
            name: 'MESSAGE_ID',
            label: translateTitle('Dams.APIMinterfaceManagement.接口编号'),
            labelHidden: false,
            isRules: true,
            disabled_edit: true,
          },
          {
            type: 'select',
            name: 'ACTIVE_FLAG',
            label: translateTitle('Dams.APIMinterfaceManagement.激活标志'),
            labelHidden: false,
            isRules: true,
            options: [
              {
                LABEL: translateTitle('Dams.APIMinterfaceManagement.是'),
                CODE: 'Y',
              },
              {
                LABEL: translateTitle('Dams.APIMinterfaceManagement.否'),
                CODE: 'N',
              },
            ],
          },
          {
            type: 'select',
            name: 'DATA_ACTION',
            label: translateTitle('Dams.APIMinterfaceManagement.入向类型'),
            labelHidden: false,
            isRules: true,
            options: [
              { CODE: '01', LABEL: 'XML' },
              { CODE: '10', LABEL: 'JSON' },
              { CODE: '20', LABEL: 'SOAP' },
              { CODE: '40', LABEL: 'DB' },
              { CODE: '42', LABEL: 'DB_MAIL' },
              { CODE: '50', LABEL: 'FTP' },
              { CODE: '51', LABEL: 'TXT' },
              { CODE: '52', LABEL: 'EXCEL' },
              // { CODE: '54', LABEL: 'MAIL' },
              { CODE: '55', LABEL: 'FTP_TXT' },
              { CODE: '57', LABEL: 'FTP_CSV' },
              { CODE: '30', LABEL: 'LDAP用户拉取' },
              { CODE: '53', LABEL: 'CSV' },
            ],
          },
          {
            type: 'select',
            name: 'OUT_DATA_ACTION',
            label: translateTitle('Dams.APIMinterfaceManagement.出向类型'),
            labelHidden: false,
            isRules: true,
            options: [
              { CODE: '01', LABEL: 'XML' },
              { CODE: '10', LABEL: 'JSON' },
              { CODE: '20', LABEL: 'SOAP' },
              { CODE: '21', LABEL: 'SOAP套JSON' },
              { CODE: '40', LABEL: 'DB' },
              { CODE: '41', LABEL: '直接调用SP' },
              { CODE: '43', LABEL: '查询' },
              { CODE: '50', LABEL: 'FTP' },
              { CODE: '52', LABEL: 'EXCEL' },
              { CODE: '53', LABEL: 'CSV' },
              { CODE: '54', LABEL: 'MAIL' },
              { CODE: '06', LABEL: 'SMS' },
              { CODE: '91', LABEL: 'WECHAT' },
              { CODE: '90', LABEL: '标准RFC' },
            ],
          },
          // {
          //   type: 'input',
          //   name: 'RESPONSE_TYPE',
          //   label: translateTitle('Dams.APIMinterfaceManagement.响应报文类型'),
          //   labelHidden: false,
          //   isRules: true,
          // },
          {
            type: 'input',
            label: translateTitle('Dams.APIMinterfaceManagement.重发设置'),
            name: 'RESEND_CONFIG',
          },
          {
            type: 'input',
            label: translateTitle('Dams.APIMinterfaceManagement.超时设置'),
            name: 'HTTP_CONFIG',
          },
          {
            type: 'input',
            name: 'RESPONSE_MODEL',
            label: translateTitle('Dams.APIMinterfaceManagement.消息描述配置'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'INTERFACE_DESC',
            label: translateTitle('Dams.APIMinterfaceManagement.接口描述'),
            labelHidden: false,
          },
          {
            type: 'select',
            name: 'ASSOCIATION_SYSTEM',
            label: translateTitle('Dams.APIMinterfaceManagement.所属系统'),
            labelHidden: false,
            options: [
              { CODE: 'DAMS', LABEL: 'DAMS' },
              { CODE: 'WMS', LABEL: 'WMS' },
              { CODE: 'LCS', LABEL: 'LCS' },
              { CODE: 'TPM', LABEL: 'TPM' },
              { CODE: 'IM', LABEL: 'IM' },
            ],
          },
          {
            type: 'input',
            name: 'RETURN_CONDITION',
            label: translateTitle('Dams.APIMinterfaceManagement.回调前置条件'),
            tableHidden: true,
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'LOG_EXPIRE_TIME',
            label: translateTitle('Dams.APIMinterfaceManagement.到期时间'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'DATA_JNDI_NAME',
            label: translateTitle('Dams.APIMinterfaceManagement.入向JNDI'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'DATA_USER_CLASS',
            label: translateTitle('Dams.APIMinterfaceManagement.入向自定义bean'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'DATA_PARAM1',
            label: translateTitle('Dams.APIMinterfaceManagement.入向自定义参数1'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'DATA_PARAM2',
            label: translateTitle('Dams.APIMinterfaceManagement.入向自定义参数2'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'DATA_PARAM3',
            label: translateTitle('Dams.APIMinterfaceManagement.入向自定义参数3'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'DATA_PARAM4',
            label: translateTitle('Dams.APIMinterfaceManagement.出向自定义参数4'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'DATA_PARAM5',
            label: translateTitle('Dams.APIMinterfaceManagement.入向自定义参数5'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'RETURN_PARAM1',
            label: translateTitle('Dams.APIMinterfaceManagement.回调自定义1'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'RETURN_PARAM2',
            label: translateTitle('Dams.APIMinterfaceManagement.回调自定义2'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'RETURN_PARAM3',
            label: translateTitle('Dams.APIMinterfaceManagement.回调自定义3'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'RETURN_PARAM4',
            label: translateTitle('Dams.APIMinterfaceManagement.回调自定义4'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'RETURN_PARAM5',
            label: translateTitle('Dams.APIMinterfaceManagement.回调自定义5'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'OUT_JNDI_NAME',
            label: translateTitle('Dams.APIMinterfaceManagement.出向JNDI'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'OUT_USER_CLASS',
            label: translateTitle('Dams.APIMinterfaceManagement.出向自定义bean'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'OUT_PARAM1',
            label: translateTitle('Dams.APIMinterfaceManagement.出向自定义参数1'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'OUT_PARAM2',
            label: translateTitle('Dams.APIMinterfaceManagement.出向自定义参数2'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'OUT_PARAM3',
            label: translateTitle('Dams.APIMinterfaceManagement.出向自定义参数3'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'OUT_PARAM4',
            label: translateTitle('Dams.APIMinterfaceManagement.出向自定义参数4'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'OUT_PARAM5',
            label: translateTitle('Dams.APIMinterfaceManagement.出向自定义参数5'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'RETURN_MESSAGE_ID',
            label: translateTitle('Dams.APIMinterfaceManagement.回调接口编号'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'RESPONSE_BEAN',
            label: translateTitle('Dams.APIMinterfaceManagement.自定义响应bean'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'SOAP_VERSION',
            label: translateTitle('Dams.APIMinterfaceManagement.SOAP版本号'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'GET_DOC_NO_TYPE',
            label: translateTitle('Dams.APIMinterfaceManagement.流水号获取类型'),
            labelHidden: false,
          },
          {
            type: 'input',
            name: 'DATA_PARAM',
            label: translateTitle('Dams.APIMinterfaceManagement.报文所在节点'),
            labelHidden: false,
          },
          {
            type: 'select',
            name: 'BATCH_FLAG',
            label: translateTitle('Dams.APIMinterfaceManagement.是否批量'),
            labelHidden: false,
            options: [
              {
                LABEL: translateTitle('Dams.APIMinterfaceManagement.是'),
                CODE: 'Y',
              },
              {
                LABEL: translateTitle('Dams.APIMinterfaceManagement.否'),
                CODE: 'N',
              },
            ],
          },
          {
            type: 'select',
            name: 'IDU_FLAG',
            label: translateTitle('Dams.APIMinterfaceManagement.增删改操作'),
            labelHidden: false,
            options: [
              { CODE: 'UPDATE', LABEL: '修改' },
              { CODE: 'D_I', LABEL: '删除再插入' },
              { CODE: 'REJECT', LABEL: '拒绝' },
              { CODE: 'INSERT', LABEL: '插入' },
            ],
          },
          {
            type: 'select',
            name: 'LOG_FLAG',
            label: '是否记录日志',
            value: 'Y',
            options: [
              {
                LABEL: translateTitle('Dams.APIMinterfaceManagement.是'),
                CODE: 'Y',
              },
              {
                LABEL: translateTitle('Dams.APIMinterfaceManagement.否'),
                CODE: 'N',
              },
            ],
          },
          {
            type: 'input',
            name: 'ADD_TIME',
            label: translateTitle('Dams.APIMinterfaceManagement.创建时间'),
            hidden: true,
            value: '',
          },
          {
            type: 'input',
            name: 'ADD_WHO',
            label: translateTitle('Dams.APIMinterfaceManagement.创建人'),
            hidden: true,
            value: '',
          },
          {
            type: 'input',
            name: 'EDIT_TIME',
            label: translateTitle('Dams.APIMinterfaceManagement.编辑时间'),
            hidden: true,
            value: '',
          },
          {
            type: 'input',
            name: 'EDIT_WHO',
            label: translateTitle('Dams.APIMinterfaceManagement.编辑人'),
            hidden: true,
            value: '',
          },
          {
            type: 'button',
            label: translateTitle('Dams.APIMinterfaceManagement.提交'),
            labelHidden: true,
            isRules: true,
          },
        ],
      },
    },
    deleteMethod: 'ApimMessageConfigRemove',
    updateMethod: 'ApimMessageConfigUpdate',
    addMethod: 'ApimMessageConfigSava',
    downloadMethod: 'apim.message.config.export',
  },
}
export default MessageConfig
